# Maintainer: Felix Yan <felixonmars@archlinux.org>

pkgname=yapf
pkgver=0.32.0
pkgrel=2
pkgdesc="Python style guide checker"
arch=('any')
url="https://github.com/google/yapf"
license=('Apache')
depends=('python')
makedepends=('python-setuptools')
checkdepends=('python-nose')
source=("https://github.com/google/yapf/archive/v$pkgver/$pkgname-$pkgver.tar.gz")
sha512sums=('c1a05a04f7558a5b51899c29010bedc105c4a4bad4b5358a903a22a39f451e03369d2b4e670ecb44a857a8fef2bf438d9da0afcbdd3a336cf037bbf480d19878')

build() {
  cd yapf-$pkgver
  python setup.py build
}

check() {
  cd yapf-$pkgver
  nosetests3
}

package() {
  cd yapf-$pkgver
  python setup.py install -O1 --root="$pkgdir"
}
